import Vue from 'vue'
import Router from 'vue-router'

Vue.use(Router);

export default new Router({
    // mode: 'history',
     base: process.env.BASE_URL,
    routes: [
        {path: '/', name: 'login', component: () => import( './views/login')},  // 登录
        {
            path: '/home',
            name: 'home',
			
            component: () => import( './views/home'),
			 children: [
			     {path: '/newCarList', name: 'newCarList', component: () => import( './views/car/newCarList')},                       // 新车列表
				 {path: '/secondCarList', name: 'secondCarList', component: () => import( './views/car/secondCarList')},                       // 二手车列表
				 {path:'/newCarDetail/:id',name:'newCarDetail',component:()=>import('./views/car/newCarDetail.vue')},//新车信息详情
				 {path:'/oldCarDetail/:id',name:'oldCarDetail',component:()=>import('./views/car/oldCarDetail.vue')},//二手车信息详情
			     {path: '/userList', name: 'userList', component: () => import( './views/user/userList')},               //用户列表
			     {path: '/orderList', name: 'orderList', component: () => import( './views/order/orderList')},                // 订单列表
			     {path: '/maintenanceUserList', name: 'maintenanceUserList', component: () => import('./views/maintenance/maintenanceUserList')},//维修人员管理
			     {path: '/factoryList', name: 'factoryList', component: () => import('./views/factory/factoryList')},//主机厂列表
			     {path: '/returnList', name: 'returnList', component: () => import('./views/order/returnList')},//退款列表
			     {path: '/inquiryList', name: 'inquiryList', component: () => import('./views/order/inquiryList')},// 询价单列表
			     { path:'/ossessmentList',name:'ossessmentList',component:()=>import('./views/order/ossessmentList')},//评估单列表
			     {path:'/carInfo',name:'carInfo',component:()=>import('./views/system/carInfo')},//车辆信息
				 {path:'/homeInfo',name:'homeInfo',component:()=>import('./views/system/homeInfoSet')},//首页信息设置
				 {path:'/rentGiveList',name:'rentGiveList',component:()=>import('./views/service/giveList')},//租车列表	
				 {path:'/rentBegList',name:'rentBegList',component:()=>import('./views/service/begList')},//找活列表
				 {path:'/operatorList',name:'operatorList',component:()=>import('./views/service/operatorList')},//机手列表
				 {path:'/findOperatorList',name:'findOperatorList',component:()=>import('./views/service/findOperatorList')},//找机手列表
				  {path:'/newOrderList',name:'newOrderList',component:()=>import('./views/order/newOrderList')},//新车订单列表
				  {path:'/newReturnList',name:'newReturnList',component:()=>import('./views/order/newReturnList')},//新车退货列表
				  {path:'/partsList',name:'partsList',component:()=>import('./views/parts/partsList')},//配件商列表
				  {path:'/internalList',name:'internalList',component:()=>import('./views/repair/internalList')},//保内维修列表
				  {path:'/externalList',name:'externalList',component:()=>import('./views/repair/externalList')},//保外维修列表
				  {path:'/partsInquiryList',name:'partsInquiryList',component:()=>import('./views/parts/partsInquiryList')},//配件询价单列表
				  {path:'/partsInquiryDetail',name:'partsInquiryDetail',component:()=>import('./views/parts/partsInquiryDetail')},//配件询价单详情
				  {path:'/partsReturnList',name:'partsReturnList',component:()=>import('./views/parts/partsReturnList')},//配件退货列表

				  
				 
			]
        },
    ]
})

